// 编写好规则
export const rules = {
  name: [
    {
      required: true,
      message: 'username is required~',
      trigger: 'blur'
    },
    {
      pattern: /^[a-z0-9_A-Z]{5,20}$/,
      message: 'The username length between 5-10~',
      trigger: 'blur'
    }
  ],
  password: [
    {
      required: true,
      message: 'password is required~',
      trigger: 'blur'
    },
    {
      pattern: /^[\w\W]{3,}$/,
      message: 'The password length greater than 3~',
      trigger: 'blur'
    }
  ]
}
